<!DOCTYPE html>
<title>Tests that a PDF file is served as "application/pdf"</title>
<script src="../resources/testharness.js"></script>
<script src="../resources/testharnessreport.js"></script>
<video></video>
<script>
async_test(function(t) {
    var video = document.querySelector("video");

    var watcher = new EventWatcher(t, video, ["loadstart", "loadedmetadata", "error"]);
    watcher.wait_for(["loadstart", "error"]).then(t.step_func_done());
    assert_equals(video.error, null);

    var movie = "resources/test.pdf";
    video.src = "http://127.0.0.1:8000/media/video-throttled-load.cgi?name=" + movie + "&throttle=99999&type=application/pdf";
});
</script>